import React, { Component } from 'react'
import Son from './Son'
import context from './context'
export default class Far extends Component {
  static contextType = context
  render() {
    return (
      <div>
        Far
        {/* 直接通过this.context获取数据 */}
        {this.context}
        <hr />
        <Son></Son>
      </div>
    )
  }
}
